package com.example.users.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import lombok.Data;

@Data
@TableName("uc_menu")
public class Menu {
    @TableId(type = IdType.AUTO)
    @NotNull(groups = com.example.users.validation.groups.Update.class, message = "id 不能为空")
    private Long id;

    private Long parentId;

    @NotBlank(groups = {com.example.users.validation.groups.Create.class}, message = "菜单名称不能为空")
    @Size(max = 64, message = "菜单名称长度不能超过64")
    private String name;
    private String path;
    private String component;
    private Integer sortOrder;
    private String icon;
    private Boolean visible;
}


